<template>
  <view>
    <view class="detail-title">
      <uni-section :title="'课程名称：' +queryObj.cid+'.'+ queryObj.cname" type="line">
      </uni-section>
    </view>
    <view class="button-box">
      <view @click="gotoPj1211">
        <text>评价标准 </text>
        <uni-icons type="list" size="18"></uni-icons>
      </view>
      <view @click="gotoPj1227">
        <text>评价权重 </text>
        <uni-icons type="map-pin-ellipse" size="18"></uni-icons>
      </view>
      <view @click="gotoPj1244">
        <text>评价成绩</text>
        <uni-icons type="medal" size="18"></uni-icons>
      </view>
      <view @click="gotoPj1254">
        <text>合班统计</text>
        <uni-icons type="staff" size="18"></uni-icons>
      </view>
    </view>
  </view>
</template>

<script>
  export default {
    data() {
      return {
        queryObj: {
          cid: '',
          cname: ''
        }

      }
    },
    onLoad(options) {
      // 将页面参数转存到 this.queryObj 对象中
      // console.log(options)
      this.queryObj.cid = options.curriulum_id || ''
      this.queryObj.cname = options.curriulum_name || ''
    },
    methods: {
      gotoPj1211() {
        uni.navigateTo({
          url: '../pj1211/pj1211?subject=' + this.queryObj.cid + '&curriulum_name=' + this.queryObj.cname
        })
      },
      gotoPj1227() { //评价权重页面
        uni.navigateTo({
          url: '../pj1227/pj1227?subject=' + this.queryObj.cid + '&curriulum_name=' + this.queryObj.cname
        })
      },
      gotoPj1244() { //评价成绩页面
        uni.navigateTo({
          url: '../pj1244/pj1244?subject=' + this.queryObj.cid + '&curriulum_name=' + this.queryObj.cname
        })
      },
      gotoPj1254() { //合班统计页面
        uni.navigateTo({
          url: '../pj1254/pj1254?subject=' + this.queryObj.cid + '&curriulum_name=' + this.queryObj.cname
        })
      }
    }
  }
</script>

<style lang="scss">
  .detail-title {
    background-color: #f5f5f5;
    margin-top: 10px;
    margin-bottom: 30px;

    .uni-section {
      // text-align: center;
      font-size: 18px;
    }
  }

  .button-box {
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    width: 300;
    height: 500px;
    // height: 440px;

    view {
      width: 210px;
      height: 60px;
      font-size: 18px;
      text-align: center;
      line-height: 60px;
      margin-bottom: 30px;
      border-radius: 10px;
      box-shadow: 2px 2px 3px 3px rgba(0, 0, 0, 0.1);
    }
  }
</style>
